package com.leetcode.www;

/**
 * Creared with IntelliJ IDEA.
 * Description:星期一到五做a道题,周末做b道题,多少天能做完n道题
 * User:yxd
 * Date:2022-04-11
 * Time:13:15
 */
import java.util.Scanner;

public class NormalC  {
    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
        int a = input.nextInt();
        int b = input.nextInt();
        int n = input.nextInt();
        int count = 0;
        int x = 1;
        while(count < n) {
            int z = x % 7;
            if(z >= 1 && z <= 5) {
                count += a;
            }else {
                count += b;
            }
            x ++;
        }
        System.out.println(x - 1);//1 1 1 1 1 2 2 1
    }
}
